package com.example.demo.create.factory.abstract_factory;

import com.example.demo.create.factory.entity.Hamburger;
import com.example.demo.create.factory.factory_method.PhoneFactory;
import com.example.demo.create.factory.intf.ElectricProduct;
import com.example.demo.create.factory.intf.Food;

/**
 * Created by zzz on 2021/1/28 下午11:30
 */
public class HuWei extends AbstractFactory {

    @Override
    public ElectricProduct createProduct() {
        ElectricProduct phone = new PhoneFactory().createProduct();
        phone.brand("HUAWEI");
        return phone;
    }

    @Override
    public Food createFood() {
        return Hamburger.builder().brand("HAUWEI").build();
    }
}
